/*
** flags.c for flag in /home/boulah_m/myprintf-2016-boulah_m
**
** Made by moustafa boulahia
** Login   <boulah_m@epitech.net>
**
** Started on  Tue Nov 15 15:04:37 2011 moustafa boulahia
** Last update Tue Jan 31 12:44:20 2012 moustafa boulahia
*/
#include "my.h"

void	octal(char *str)
{
  int	a;

  a = 0;
  while (str[a] != '\0')
    {
      if (str[a] < 32 || str[a] >= 127)
	{
	  my_putchar(92);
	  my_putnbr(0);
	  my_putnbr_base(str[a], "01234567");
	  a = a + 1;
	}
      else
	{
	  my_putchar(str[a]);
	  a = a + 1;
	}
    }
}
